﻿//-----------------------------------------------------------------------------
//
// Copyright (C) Microsoft Corporation.  All Rights Reserved.
//
//-----------------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.IO;
using CSharpSourceEmitter;
using Microsoft.Cci;
using Microsoft.Cci.MetadataReader;
using Microsoft.Cci.ILToCodeModel;
using Microsoft.Cci.Contracts;

namespace Mutator
{
    public class SourceRelatedVisitor : CSharpSourceEmitter.SourceEmitter
    {

        public SourceRelatedVisitor(ISourceEmitterOutput sourceEmitterOutput, IMetadataHost host, ContractProvider/*?*/ contractProvider, PdbReader/*?*/ pdbReader, bool noIL)
            : base(sourceEmitterOutput)
        {
            this.host = host;
            this.contractProvider = contractProvider;
            this.pdbReader = pdbReader;
            this.noIL = noIL;
        }

        ContractProvider/*?*/ contractProvider;
        IMetadataHost host;
        PdbReader/*?*/ pdbReader;
        bool noIL;

        public override void Visit(IMethodDefinition methodDefinition)
        {
            PrintToken(CSharpToken.Indent);
            PrintMethodDefinitionVisibility(methodDefinition);
            PrintMethodDefinitionModifiers(methodDefinition);
            PrintMethodDefinitionReturnType(methodDefinition);
            PrintToken(CSharpToken.Space);
            PrintMethodDefinitionName(methodDefinition);
            if (methodDefinition.IsGeneric)
            {
                Visit(methodDefinition.GenericParameters);
            }
            Visit(methodDefinition.Parameters);
            //Visit(methodDefinition.Body);
        }

      
    }

}